-
-
Notifications
You must be signed in to change notification settings - Fork 4.3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat(issue-views): Change add view button to just + icon near starred views header' #87360
Conversation
height: 14px !important; | ||
margin: 0 !important; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ugh I hate when we run into high specificity CSS styles
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I wonder if adding mini
is conflicting with the height
prop you're sending?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It might, but mini
also controls the width of the loading ring. Without it here, the width looks too big relative to the space its contained in.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ah that makes sense
@@ -149,12 +151,13 @@ export function IssueViewNavItemContent({ | |||
dragListener={false} | |||
dragControls={controls} | |||
style={{ | |||
...(isDragging | |||
...(isDragging || scrollPosition === 0 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This kinda fixes that really annoying issue where views wouldn't animate in and out as a result of the originY styles. We only need to apply those styles if the user has scrolled down on the page, since that's what triggers the framer motion bug.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Would be nice to add a comment here about why this is necessary since it will be very confusing to future readers!
position: relative; | ||
background-color: ${p => p.theme.translucentSurface200}; | ||
background-color: ${p => (p.grabbing ? p.theme.translucentSurface200 : 'transparent')}; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
<SecondaryNav.Section | ||
title={ | ||
<TitleWrapper> | ||
{t('Starred Views')} | ||
<IssueViewAddViewButton baseUrl={baseUrl} /> | ||
</TitleWrapper> | ||
} | ||
> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is moved in from navigation.tsx
static/app/components/nav/issueViews/issueViewAddViewButton.tsx
Outdated
Show resolved
Hide resolved
Co-authored-by: Malachi Willey <[email protected]>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
A couple suggestions but looks good!
Moves the Add View Button from below the views to the right of the "Starred Views" header. Adds a tooltip that says "Add View"
Before:
After:
Includes a couple of annotated drive by changes that aren't super related